#define _CRT_SECURE_NO_WARNINGS 1

#include<stdio.h>
//#define INT_PTR int*
//typedef int* int_ptr;
//
//#define N 4
//#define Y(n) ((N+2)*n) ((6) * 5 + 1)
//
//INT_PTR a, b;
//int_ptr c, d;
//int main()
//{
//	int z = 2 * (N + Y(5 + 1));
//	return 0;
//}
//
//#include<stddef.h>
////struct S
////{
////	int a;
////	char c;
////	double d;
////};
////
////#define OFFSETOF(type,name)   (size_t)&(((type*)0)->name) 
////
////int main()
////{
////	struct S s;
////	printf("%d\n", OFFSETOF(struct S, a));
////	printf("%d\n", OFFSETOF(struct S, c));
////	printf("%d\n", OFFSETOF(struct S, d));
////	return 0;
////}
//
////#define SWAP_BIT(x)  (x = (((x & 0x55555555) << 1) + ((x & 0xaaaaaaaa) >> 1)))
////
////int main()
////{
////	int a = 5;
////	SWAP_BIT(a);
////	printf("%d", a);
////	return 0;
////}
//
//void Func1()
//{
//	int a = 0;
//	printf("%p\n", &a);
//}
//
//void Func2()
//{
//	int b = 0;
//	printf("%p\n", &b);
//}
//
//int main()
//{
//	Func1();
//	Func2();
//
//
//	return 0;
//}


#include"Seqlist.h"

void test1()
{
	SL s;
	SLInit(&s);
	SLPushBack(&s, 1);
	SLPushBack(&s, 2);
	SLPushBack(&s, 3);
	SLPushBack(&s, 4);
	SLPrint(&s);
	SLPushFront(&s, 5);
	SLPushFront(&s, 4);
	SLPushFront(&s, 3);
	SLPushFront(&s, 2);
	SLPrint(&s);
	SLDestroy(&s);
}
void test2()
{
	SL s;
	SLInit(&s);
	SLPushBack(&s, 1);
	SLPushBack(&s, 2);
	SLPushBack(&s, 3);
	SLPushBack(&s, 4);
	SLPrint(&s);
	SLInsert(&s, 3, 6);
	SLInsert(&s, 2, 4);
	SLPrint(&s);
	SLErase(&s, 2);
	SLPrint(&s);
	SLDestroy(&s);
}

void test3()
{
	SL s;
	SLInit(&s);
	SLPushBack(&s, 1);
	SLPushBack(&s, 2);
	SLPushBack(&s, 3);
	SLPushBack(&s, 4);
	/*int pos = SLFind(&s, 2);
	printf("%d\n", pos);*/
	Modify(&s, 1, 5);
	SLPrint(&s);
	SLDestroy(&s);
}
int main()
{
	test3();
	return 0;
}